/*
 * @Description: 路由表
 {
        path: '',  必须为完全路径
        name: '',
        component:()=>import(),
        meta: {
          title: '', 菜单标题
          keepAlive: true, 是否缓存该组件
          icon:'' ,  菜单图标，可以使用svg和饿了么图标
          hidden:false,  是否隐藏该菜单项
          permission:[]  权限数组，该菜单需要哪些权限才可以访问
        },
      },
 * @Autor: 人生
 * @Date: 2021-05-22 15:37:53
 * @,@LastEditors: ,: 人生
 */
import { RouteRecordRaw } from 'vue-router'
import RouteView from './RouteView.vue'
export const menuRoutes: Array<RouteRecordRaw> = [
  {
    path: '/index',
    name: 'Documentation',
    component: RouteView,
    redirect: '/index/menu',
    meta: {
      title: 'Documentation',
      icon: 'documentation',
      keepAlive: true
    },
    children: [
      {
        path: '/index/menu',
        component: () => import('@/views/dashboard/index.vue'),
        meta: {
          title: 'Menu',
          icon: 'list',
          hidden: false
        }
      }
    ]
  },
  {
    path: 'http://www.baidu.com',
    name: 'baidu',
    component: RouteView,
    meta: {
      title: '百度',
      icon: 'guide'
    }
  },
  {
    path: '/guide',
    name: 'Guide',
    component: { render() { return 'Guide' } },
    meta: {
      title: 'Guide',
      icon: 'guide'
    }
  },
  {
    path: '/system',
    component: RouteView,
    redirect: '/system/user',
    meta: {
      title: 'System',
      icon: 'lock',
      keepAlive: true
    },
    children: [
      {
        path: '/system/menu',
        component: { render() { return 'Menu' } },
        meta: {
          title: 'Menu',
          icon: 'list'
        }
      },
      {
        path: '/system/role',
        component: { render() { return 'role' } },
        meta: {
          title: '权限管理',
          icon: 'el-icon-platform-eleme'
        }
      },
      {
        path: '/system/user',
        component: { render() { return 'user' } },
        meta: {
          title: 'User',
          icon: 'list'
        }
      }
    ]
  }

]
